<template>
    <ul>
        <li>id:{{ params.id }}</li>
        <li>标题:{{ params.title }}</li>
        <li>内容:{{ params.content }}</li>
    </ul>

</template>

<script setup name="Detail" lang="ts">
import { ref, reactive,toRefs } from 'vue'
import { useRoute } from 'vue-router'
const route = useRoute()
// 解构赋值，toRefs 将 route 对象中的属性转换为响应式对象
let {params} = toRefs(route)
</script>
